package scaladuct

import lists.scala.{ListForProperty, ListsManager}
import lists.{ListsSource}

/**
 * <p>
 * Created by IntelliJ IDEA.
 * User: zslajchrt
 * Date: Dec 13, 2010
 * Time: 8:37:22 PM
 */

class ListsSourceStarter1 extends Starter[String] with ListsSource {

  def newInstance(): String = phaseOne("", Enum1.VALUE1)

  def phaseOne(a: String, b: Enum1): String = {
    ""
  }

  def destroy(instance: String) = null

  def listsForPhase(phase: String) = phase match  {
    case "phaseOne" => {
      Some(new ListsManager {
        def scalaListForProperty(property: Property[AnyRef]) = property.name match {
          case "parameter0" => {
            Some(new ListForProperty(property, List("Value1", "Value2"), true, false))
          }
          case _ => None
        }
      })
    }
    case _ => None
  }
}